import React, { useRef } from "react"
import { Table } from "antd"
function DataTable({ pagination, ...restProps }) {
  const countRef = useRef(null)
  return (
    <div className="bg-white px-10px box-border">
      <Table
        ref={countRef}
        {...restProps}
        bordered
        size="middle"
        pagination={{
          ...pagination,
          showSizeChanger: false,
          showQuickJumper: true,
          showTotal: () => `共${pagination.total}条`
        }}
        // scroll={{
        //   y: scrollY
        // }}
      />
    </div>
  )
}
export default DataTable
